i = 0
while i <= 5:
    i += 1
    print('星期为：', i)
    if i == 3:
        break
i = 1
while i <= 5:
    if i == 3:
        break
    print('星期为： ', i)
    i += 1

for i in range(1, 6):
    print('星期为：', i)
    if i == 3:
        break

for i in range(1, 6):
    if i == 3:
        break
    print('星期为：', i)

i = 0
while i < 5:
    i += 1
    if i == 4:
        continue
    print('星期为：', i)

for i in range(1, 6):
    if i == 4:
        continue
    print('星期为：', i)


def shi():
    print('静夜思---李白')
    print('床前明月光， 疑是地上霜')
    print('举头望明月， 低头思故乡')


shi()


def add():
    a, b = 6, 7
    s = a * b
    print('a和b的积为：', s)
    return a + b


c = add()
print(c)


def add(a, b):
    print(a + b)


add(1, 3)

c = 7
d = 9
add(c, d)

add(4 * 5, 9 % 3)

e = 0
add(8, e * 4 + 3)


def sc(a, b, c):
    print('张三成绩为：', a)
    print('李四成绩为：', b)
    print('王五成绩为：', c)


sc(30, 52, 98)

sc(b=52, c=98, a=30)


def reg(name, age, sex='女'):
    print('姓名： {} 年龄： {} 性别： {}'.format(name, age, sex))


reg('小丽', 20)
reg('小张', 21, '男')

def fav(*fr):
    print('我喜欢的水果有：')
    for i in fr:
        print(i)



fav('苹果')
fav('苹果', '香蕉', '芒果',)
fav('苹果', '西瓜', '橙子', '榴莲', '草莓')



def show(a, b, *l):
    print(a)
    print(b)
    print(l)


show(1, 2, 3, 4, 85)


def rectangle():
    a =int(input('请输入矩形的长:'))
    b =int(input('请输入矩形的宽:'))
    s = a*b
    c = 2*(a+b)
    print('该矩形的面积为：', s)
    print('该矩形的周长为：', c)

rectangle()

